package com.springcloud.demo.consumer;

import com.springcloud.demo.channel.MyDeaultSink;
import org.springframework.cloud.stream.annotation.EnableBinding;
import org.springframework.cloud.stream.annotation.StreamListener;
import org.springframework.stereotype.Component;

@Component
@EnableBinding(MyDeaultSink.class)
public class MessageDefaultConsumer {

    @StreamListener(MyDeaultSink.DEFAULT_INPUT)
    public void receive(String message) {
        System.out.println("message = " + message);
    }
}
